Post

Replies

Boosts

Views

Activity

PDFKit create document version is 1.3 can we create an PDF 1.7 document?
Working with PDFkit on MacOS 12.6 and created a new PDFDocument instance. checking the HEX code of this PDF document and notice this, At the beginning there is "%PDF-1.3%". Is it possible to create a new PDFDocument in PDF Spec 1.7 version instead? if not possible with current version, any plan in the future? is there a plan to have equivalence of PDFKit in SWIFTUI world around the corner? thanks
0
0
1k
Oct ’22
Verify Receipt get 21003 instead of 0 from sandbox, 21007 from buy(OK)
app server in firebase cloud functions. TestFlight internal tester to purchase and forward the receipt to sandbox - 21003(not sure why not 0...) receipt00.txt when verify with production(buy) : result is 21007 (this is expected) The encoded receipt attached. The code of loading and base64 encoding is below : My Question: I expect to get 21007 from buy and got it, I expect to get 0 from Sandbox but end up with 21003. How can I fix this?  do{                 let receiptData = try Data(contentsOf: appStoreReciptUrl,options: .alwaysMapped)                 if let filename = getFileName(basename: "receipt"){                     await writeToFile(data: receiptData,fileName: filename)                 }                 return receiptData.base64EncodedString(options: [])                              }catch{
2
0
1.9k
Sep ’22
SwiftUI toolbarItem and accessibility label issue
run into an issue of SWIFT UI with toolbarItem (navigationBarItem for iOS) and it turns out I have the accessibility (label:) in my item and that cause the swiftUI to have UIConstraint breaking issues. this could cause the UI to never navigate so no longer useful. try to put the following control in the toolbar, you might need to add some principle toolbar title item and other toolbar item. the problem can be fixed by removing the accessibility line. var purchaseButtonView: some View{         NavigationLink(             destination: PurchaseView(),             label: {                 Image(systemName: entitlement.localEmerald ? "hare.fill" : "cart.fill")                     .foregroundColor( entitlement.localEmerald ? Color.yellow :                         products.items.count == 0 ? Color.gray : Color.blue )                 accessibility(label: Text("purchase")) //---- this accessibilityLabel will cause the swiftUI to no longer navigate             })             .disabled(products.items.count == 0 )     }
0
0
811
Apr ’21